Hello,
I would like people to provide feed back regarding attached script. Is a better way of printing the RTM(<time and memory)? Any other comments would be appreciated. Thank you. -Jim EHcnck - Wed Sep 25 14:19:10 EDT 2013 |
Re: improve existing code(help appreciated) Didn't study very hard; didn't see anything serious; but have these observations:
Did your allocated units checking show a problem? -Louie |
Re: improve existing code(help appreciated) A really obvious improvement would be to add comments to describe what the script is doing. This may be clear to you. Now. But in a couple of years when you or someone else needs to update it, the obvious will become obscure.
- David Bond |
Re: improve existing code(help appreciated) OK, so I actually ran it and displayed the Dialog. Like it better. Got some more thoughts, none serious.
Am pushing buttons. At first I thought this was a "Link" edit dialog but I see it is a "LinkSet" edit dialog. I'd be tempted to have a "Linkset" listView, which when selected displays the "Links" in the existing listView. the LinkSet listView could perhaps include all Linkset Pairings as well as existing links. Looks good. See no obvious gross ineffeciencies. -Louie |
Re: improve existing code(help appreciated) llandale - Thu Sep 26 10:31:28 EDT 2013 OK, so I actually ran it and displayed the Dialog. Like it better. Got some more thoughts, none serious.
Am pushing buttons. At first I thought this was a "Link" edit dialog but I see it is a "LinkSet" edit dialog. I'd be tempted to have a "Linkset" listView, which when selected displays the "Links" in the existing listView. the LinkSet listView could perhaps include all Linkset Pairings as well as existing links. Looks good. See no obvious gross ineffeciencies. -Louie Hello, Thank you for the feedback attempted to change the block to show but when I did then executed the buttons(Edit, etc.) it would close the dialog..not sure of the correct syntax help would be appreciated. I rewrote the printRTM rather the using a dialog box I use html..faster results. Is there any way of increase the performance when filling the listview? Thank you. -Jim Attachments transferLinks(v1.19).dxl |
Re: improve existing code(help appreciated) EHcnck - Thu Sep 26 17:30:38 EDT 2013 Hello, Thank you for the feedback attempted to change the block to show but when I did then executed the buttons(Edit, etc.) it would close the dialog..not sure of the correct syntax help would be appreciated. I rewrote the printRTM rather the using a dialog box I use html..faster results. Is there any way of increase the performance when filling the listview? Thank you. -Jim As for "block" vrs "show": Your callbacks generally need to know if it is "show"n or "block"ed. "show" Execution ends at "show"; there is no way to get the statement after "show" to execute. Execitution picks up again in the callbacks. The close callback should hide and destroy the dialog and cleanup global data structures. "show"n dialogs have no "release". "block" Execution after the "block" statement picks up after the code that "releases" the dialog ends. I believe the following advise is highly desirable, but in any case it is "good": you should "destroy" the dialog only after the "block". You can clean up your data structures (e.g. delete Skip lists) either after "block" (my advise) or in the close callback (not my advise); but otherwise the close callback should only "release"; must not 'destroy". Note that function "ack" displays a "block"ed dialog. I played around "realizing" a dialog without actually "show"ing nor "block"ing it. IIRC these generally behaved as if they were "shown" but there were a couple obscure cases where it didn't. Seems to me that the dxl code did not actually officially "end", which only matters if you are doing something obscure. But I did successfully "realize" one dialog and then "show" or "block" another on top of it. -Louie |
Re: improve existing code(help appreciated) llandale - Fri Sep 27 11:55:28 EDT 2013 As for "block" vrs "show": Your callbacks generally need to know if it is "show"n or "block"ed. "show" Execution ends at "show"; there is no way to get the statement after "show" to execute. Execitution picks up again in the callbacks. The close callback should hide and destroy the dialog and cleanup global data structures. "show"n dialogs have no "release". "block" Execution after the "block" statement picks up after the code that "releases" the dialog ends. I believe the following advise is highly desirable, but in any case it is "good": you should "destroy" the dialog only after the "block". You can clean up your data structures (e.g. delete Skip lists) either after "block" (my advise) or in the close callback (not my advise); but otherwise the close callback should only "release"; must not 'destroy". Note that function "ack" displays a "block"ed dialog. I played around "realizing" a dialog without actually "show"ing nor "block"ing it. IIRC these generally behaved as if they were "shown" but there were a couple obscure cases where it didn't. Seems to me that the dxl code did not actually officially "end", which only matters if you are doing something obscure. But I did successfully "realize" one dialog and then "show" or "block" another on top of it. -Louie Hi, I'm trying to tie my dialog with the module so if you close the module it closes the dialog box. When using "modDB_tie(mainDB)" then changing edit-mode it closes the dialog box using "styleSubWindow" it forces the dialog to be on top of the module is there any way on tying them together with out either closing the dialog box when switching edit-modes or have the dialog on top? Thank you.
//mainDB Attachments transferLinks(v1.24) .dxl |
Re: improve existing code(help appreciated) EHcnck - Mon Jan 20 22:23:32 EST 2014 Hi, I'm trying to tie my dialog with the module so if you close the module it closes the dialog box. When using "modDB_tie(mainDB)" then changing edit-mode it closes the dialog box using "styleSubWindow" it forces the dialog to be on top of the module is there any way on tying them together with out either closing the dialog box when switching edit-modes or have the dialog on top? Thank you.
//mainDB Looking at modueDB.inc, you can
-Louie |